//
//  UIButton+Property.h
//  RiceBasket
//
//  Created by DwZeng on 2021/1/15.
//

#import <UIKit/UIKit.h>

@interface UIButton (Property)


//初始化方法
+(UIButton* (^)())init;
//初始化方法(参数为frame)
+(UIButton* (^)(CGRect frame))initFrame;
//初始化button
+(UIButton* (^)(UIButtonType type))initType;
//设置view的backgroundColor
-(UIButton* (^)(NSString *color))bgColor;
//设置文字
-(UIButton* (^)(NSString *title,UIControlState state))title;
//设置文字大小
-(UIButton* (^)(CGFloat font))titleFont;
//设置文字颜色
-(UIButton* (^)(NSString *color,UIControlState state))titleColor;
//设置图片
-(UIButton* (^)(UIImage *image,UIControlState state))image;
//设置背景图片
-(UIButton* (^)(UIImage *image,UIControlState state))bgImage;
//给button添加事件
-(UIButton* (^)(id target,SEL selector,UIControlEvents event))addTarget;
//设置frame
-(UIButton *(^)(CGRect frame))setFrame;


//快速创建bottomButton
+(UIButton *)bottomButton:(CGRect)frame Title:(NSString *)title Font:(CGFloat)font;
/** 快速创建带边框button  */
+(UIButton *)borderButton:(CGRect)frame Title:(NSString *)title Font:(CGFloat)font color:(NSString *)color;


@end
